<!DOCTYPE html>
<html lang="zh-CN" xmlns:th="http://www.thymeleaf.org"
	xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<title>【顺风车】 - 首页</title>
<link rel="stylesheet" href="../../static/assets/css/amazeui.css" th:href="@{/assets/css/amazeui.min.css}" />
<link rel="stylesheet" href="../../static/assets/css/common.min.css" th:href="@{/assets/css/common.min.css}" />
<link rel="stylesheet" href="../../static/assets/css/amaze.min.css" th:href="@{/assets/css/amaze.min.css}" />
<link rel="stylesheet" href="../../static/assets/css/other.min.css" th:href="@{/assets/css/other.min.css}" />
</head>
<body class="register-container">
	<div th:include="common/header::header"></div>

	<!--===========layout-container================-->
	<div class="layout-container">

		<div class="amz-banner" style="background-color: #f5f5f5;">
			<div class="amz-container" data-am-scrollspy="{animation: 'scale-up', repeat: false}">
				<h1>让天更蓝，让水更清</h1>
				<p>顺风车 - 拼车出行，惠己利人</p>
				<p>
					<a sec:authorize="${hasAnyAuthority(1)}" th:href="@{/front/chepiao}" class="am-btn am-btn-sm get-btn">发布信息</a>
					<a sec:authorize="${hasAnyAuthority(2)}" th:href="@{/front/qiangdan}" class="am-btn am-btn-sm get-btn">发布信息</a>
				</p>
			</div>
		</div>

		<div class="am-g am-container" style="margin-top: 20px;">
			<section class="am-panel am-panel-primary">
				<div class="am-scrollable-horizontal">
					<table class="am-table am-table-hover am-table-compact am-table-centered am-text-nowrap">
						<thead style="background-color: #0e90d2; color: #ffffff;">
							<tr>
								<th class="am-text-middle am-text-sm" width="80">头像</th>
								<th class="am-text-middle am-text-sm" width="120">名称</th>
								<th class="am-text-middle am-text-sm">出发地<br />目的地
								</th>
								<th class="am-text-middle am-text-sm" width="120">出发日期</th>
								<th class="am-text-middle am-text-sm" width="120">出发时间</th>
								<th class="am-text-middle am-text-sm" width="60">票价</th>
								<th class="am-text-middle am-text-sm" width="60">预订</th>
							</tr>
						</thead>
						<tbody>
							<tr th:each="order : ${orderList}">
								<td>
									<img th:src="${order.user.imageName}" class="am-img-responsive am-circle" alt="" width="80" height="80" />
								</td>
								<td class="am-text-middle am-text-xs" th:text="${order.user.realName}"></td>
								<td class="am-text-middle am-text-xs am-text-left">
									<p class="am-text-truncate">
										<span class="am-badge am-badge-secondary am-radius">起</span>
										<span th:utext="${order.startProvinces}?${order.startProvinces.province}"></span>
										<span th:text="${order.startCities}?${order.startCities.city}"></span>
										<span th:text="${order.startAddress}"></span>
										<br />
										<span class="am-badge am-badge-danger am-radius">终</span>
										<span th:utext="${order.stopProvinces}?${order.stopProvinces.province}"></span>
										<span th:text="${order.stopCities}?${order.stopCities.city}"></span>
										<span th:text="${order.stopAddress}"></span>
									</p>
								</td>
								<td class="am-text-middle am-text-xs" th:text="${order.goDate}"></td>
								<td class="am-text-middle am-text-xs" th:text="${order.goTime}"></td>
								<td class="am-text-middle am-text-xs" th:text="${order.price1}"></td>
								<td class="am-text-middle am-text-xs">
									<a sec:authorize="${hasAnyAuthority(1)}" th:href="@{'/front/order/reserve/yuding/'+${order.id}}"
										class="am-btn am-btn-primary am-text-xs">预订</a>
									<a sec:authorize="${hasAnyAuthority(2)}" th:href="@{'/front/order/reserve/qiangdan/'+${order.id}}"
										class="am-btn am-btn-primary am-text-xs">抢单</a>
								</td>
							</tr>
						</tbody>
					</table>
				</div>
				<div class="am-panel-footer">
					<a th:href="@{/front/chepiao}" sec:authorize="${hasAnyAuthority(1,0)}"
						class="am-btn am-btn-primary am-center am-radius am-btn-xl">&nbsp;查&nbsp;看&nbsp;更&nbsp;多&nbsp;数&nbsp;据&nbsp;</a>
					<a th:href="@{/front/qiangdan}" sec:authorize="${hasAnyAuthority(2)}"
						class="am-btn am-btn-primary am-center am-radius am-btn-xl">&nbsp;查&nbsp;看&nbsp;更&nbsp;多&nbsp;数&nbsp;据&nbsp;</a>
				</div>
			</section>
		</div>


	</div>

	<div th:include="common/footer::footer"></div>

	<script src="../../static/assets/js/jquery-2.1.0.js" charset="utf-8" th:src="@{/assets/js/jquery-2.1.0.js}"></script>
	<script src="../../static/assets/js/amazeui.js" charset="utf-8" th:src="@{/assets/js/amazeui.js}"></script>
	<script src="../../static/assets/js/common.js" charset="utf-8" th:src="@{/assets/js/common.js}"></script>
</body>

</html>
